home *** CD-ROM | disk | FTP | other *** search
- var xspeed = Math.random() * 2 + 2;
- if(Math.random() > 0.5)
- {
- xspeed *= -1;
- }
- var yspeed = 0;
- var temp_scale = 0.05 + 1 * Math.random();
- this._yscale *= temp_scale;
- this._xscale *= temp_scale;
- this.onEnterFrame = function()
- {
- this._x += xspeed;
- this._y += yspeed;
- this._yscale *= 0.95;
- this._xscale *= 0.95;
- yspeed -= 0.1 + 4 * Math.random();
- xspeed += Math.random() * 4 - 2;
- if(Math.random() > 0.6)
- {
- this.prevFrame();
- }
- };
-